<html>
<body>
<script>
(function(){
  var queryString = location.search.replace(/^\?/,"").split(/\&/);
  var queryStringLength = queryString.length;
  var type, url, method, gettingQuery = [], environQuery = [], pairMatchResult, headers;
  for(var i = 0; i < queryStringLength; ++i){
    var metaArgument = queryString[i];
    if(metaArgument.indexOf("type=")===0)
      type = metaArgument.replace(/type=/,"");
    else if(metaArgument.indexOf("query=")===0){
      var environ = metaArgument.replace(/query=/,"").split("|");
      for(var j = 0, argument; j < environ.length; ++j)
        if(argument = environ[j]){
          // In IE 6.0, String.prototype.split has bug.
          pairMatchResult = argument.match(/([^\=]*)=(.*)/);
          environQuery.push(pairMatchResult ?
            [decodeURIComponent(pairMatchResult[1]),decodeURIComponent(pairMatchResult[2])]
            : [decodeURIComponent(argument)]
          );
        }
    } else if(metaArgument.indexOf("method=")===0)
      method = metaArgument.replace("method=","");
    else if(metaArgument.indexOf("url=")===0)
      url = decodeURIComponent(metaArgument.replace("url=",""));
  }
  if(!url)
    throw new Error("argument url is not defined!");
  if(!url.match(/^((?:(?:(?:[a-zA-Z]+)?\:\/\/(?:(?:[^\/\:\@\?\#]+)(?:\:(?:[^\/\:\@\?\#]+))?\@)?[^\/\:\@\?\#]+(?:\.[^\/\:\@\?\#])*\.?(?:\:\d+)?)?)?(?:\/(?:[^\/\?\#]+(?:\/[^\/\?\#]+)*\/?)?)?)((?:\?[^\?\#]*)?)((?:\#[^\#]*)?)$/))
    throw new Error("wrong format of argument url!");
  var f = document.createElement("form");
  f.action = url;
  f.method = method === undefined ? "POST" : method;
  f.acceptCharset = "utf-8";
  for(var i = 0; i < environQuery.length; ++i){
    var input = document.createElement("input");
    input.type = "hidden";
    input.name = environQuery[i][0];
    input.value = environQuery[i][1] || "";
    f.appendChild(input);
  }
  document.body.appendChild(f);
  f.submit();
})();
</script>
</body>
</html>